let username = document.querySelector('#username')
let email = document.querySelector('#email')
let password = document.querySelector('#password')
let login = document.querySelector('#login')

login.addEventListener('click',function(){
    if (username.value.length < 4){
        username.style.color = 'red'
        username.value = "请输入正确的用户名"
    }
    else if(email.value.length < 4){
        email.style.color = 'red'
        email.value = "请输入正确的邮箱"
    }
     else if(password.value.length < 4){
        password.style.color = 'red'
        password.value = "请输入正确的密码"
    }else{
        location.href = '../index.html'
    }
})
